﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;
using System.Diagnostics.Contracts;

namespace DataStructure.Interview
{
    public class Question55
    {
        public static int BitSwapRequired(int a, int b)
        {
            int count = 0;
            for (int i = a ^ b; i != 0; i=i>>1)
            {
                count += count & 1;
            }
            return count;
        }
    }
}
